<?php
namespace app\admin\model;

class Crontab extends \think\Model
{    
    // 自动写入时间戳字段
    protected $autoWriteTimestamp = 'int';

    protected $readonly = [];

    // 定义时间戳字段名
    protected $createTime = 'createtime';
    protected $updateTime = 'updatetime';

    protected $auto = [];
    
    // 追加属性
    protected $append = [
        // 'status'
    ];

    protected $type = [];

    protected function setBegintimeAttr($value,$data) {
        return strtotime($value);
    }

    protected function setEndtimeAttr($value,$data) {
        return strtotime($value);
    }

    protected function setExecutetimeAttr($value, $data) {
        return strtotime($value);
    }
}